class MyThread1 extends Thread{
    public MyThread1() {
    }

    public MyThread1(String name) {
        super(name);
    }

    @Override
    public void run() {
        for (int i = 0; i < 100; i++) {
            System.out.println(getName()+"@"+i);

        }
    }
}
public class Demo13heima {
    public static void main(String[] args) throws InterruptedException {
//        MyThread1 t1 = new MyThread1("小飞机");
//        MyThread1 t2 = new MyThread1("xiaodani");
//        t1.setName("ssss");
//        t2.setName("ddddd");
//
//        t1.start();
//        t2.start();
        System.out.println("aaaaaaaaa");
        Thread.sleep(2000);
        System.out.println("ddddddddd");
        System.out.println(Thread.currentThread().getName());

    }
}
